<script setup>
import {defineProps} from 'vue'
import {useRouter} from "vue-router";
const router = useRouter()
defineProps({
  title: {
    type: String,
    default: '标题'
  }
})
const onClickLeft = () => {
  router.go(-1)
}
</script>

<template>
  <van-nav-bar
      :title="title"
      left-arrow
      @click-left="onClickLeft"
  />
</template>

<style scoped lang="less">
::v-deep{
  .van-icon-arrow-left{
    color: #000;
  }
}

</style>